package com.ylfstu.Homework.homework13;

public class Person {
    private String name;
    private char gender;
    private int age;

    public void printMessage(){
        System.out.println("姓名:"+name + "\n年龄:" + age  + "\n性別:" + gender);
    }

    public String play() {
        return name + "爱玩";
    }

    public Person(String name, char gender, int age) {
        this.name = name;
        this.gender = gender;
        this.age = age;
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public char getGender() {
        return gender;
    }

    public void setGender(char gender) {
        this.gender = gender;
    }

    public int getAge() {
        return age;
    }

    public void setAge(int age) {
        this.age = age;
    }
}
